package com.sky.service;

import com.sky.dto.*;
import com.sky.entity.OrderDetail;
import com.sky.entity.Orders;
import com.sky.result.PageResult;
import com.sky.vo.OrderPaymentVO;
import com.sky.vo.OrderStatisticsVO;
import com.sky.vo.OrderSubmitVO;
import com.sky.vo.OrderVO;

import java.io.IOException;
import java.util.List;

public interface OrdersService {
    /**
     * 用户下单
     * @param ordersSubmitDTO
     * @return
     */
    OrderSubmitVO submit(OrdersSubmitDTO ordersSubmitDTO);

    /**
     * 订单支付
     * @return
     */
    OrderPaymentVO payment(OrdersPaymentDTO ordersPaymentDTO) throws Exception;

    /**
     * 订单支付 -虚假的支付成功
     * @param ordersPaymentDTO
     * @return
     * @throws Exception
     */
    void update(OrdersPaymentDTO ordersPaymentDTO);

    /**
     * 查询订单详情
     * @param id
     * @return
     */
    Orders findOrderDetailByOrderId(Long id);

    /**
     * 查询历史订单
     * @param ordersPageQueryDTO
     * @return
     */
    PageResult findHistoryOrdersPage(OrdersPageQueryDTO ordersPageQueryDTO);

    /**
     * @Author Anson
     @Date   2023/8/2 14:33
     @Param        * @param id
     @param retrieveOrderStatus
     @Description  订单状态更变
     @Return_type
     */

    void ordersStatus(Long id, Integer retrieveOrderStatus);
}
